package main

import (
	"bufio"
	"fmt"
	"os"
)

func main() {
	sc := bufio.NewScanner(os.Stdin)
	sc.Scan()
	text := sc.Text()

	var j int
	for i := 0; i < len(text); i++ {
		if text[i] >= '1' && text[i] <= '3' {
			j = i + 1
			for ; j < len(text) && text[j] >= '0' && text[j] <= '9'; j++ {
			}
			if j-i == 4 {
				fmt.Printf("%s ", text[i:j])
			}
			i = j - 1
		}
	}
}
